<html>
<head><meta charset="utf-8"><title>Long hangs in publish_diagnostics · t-compiler/rust-analyzer · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/index.html">t-compiler/rust-analyzer</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/Long.20hangs.20in.20publish_diagnostics.html">Long hangs in publish_diagnostics</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="218867030"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/Long%20hangs%20in%20publish_diagnostics/near/218867030" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jonas Schievink  [he/him] <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/Long.20hangs.20in.20publish_diagnostics.html#218867030">(Dec 04 2020 at 17:47)</a>:</h4>
<p>Did anything change in the <code>hir_ty</code> diagnostics recently? I'm seeing pretty long hangs in there now:</p>
<div class="codehilite"><pre><span></span><code>11841ms - publish_diagnostics
    11834ms - diagnostics
        11645ms - Module::diagnostics
            11638ms - Module::diagnostics
                  715ms - validate_module_item
                      711ms - find_all_refs
                          710ms - FindUsages:search
                                1ms - classify_name (161 calls)
                               50ms - classify_name_ref (826 calls)
                                0ms - crate_def_map:wait (1 calls)
                              155ms - descend_into_macros (798 calls)
                              463ms - parse_query (200 calls)
                                0ms - search_scope (1 calls)
</code></pre></div>



<a name="218867561"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/Long%20hangs%20in%20publish_diagnostics/near/218867561" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Florian Diebold <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/Long.20hangs.20in.20publish_diagnostics.html#218867561">(Dec 04 2020 at 17:51)</a>:</h4>
<p>that seems like it's some quickfix calling <code>find_all_refs</code>?</p>



<a name="218867860"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/Long%20hangs%20in%20publish_diagnostics/near/218867860" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Florian Diebold <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/Long.20hangs.20in.20publish_diagnostics.html#218867860">(Dec 04 2020 at 17:53)</a>:</h4>
<p>hm well that's only a small part of the time though</p>



<a name="218869327"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/Long%20hangs%20in%20publish_diagnostics/near/218869327" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jonas Schievink  [he/him] <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/Long.20hangs.20in.20publish_diagnostics.html#218869327">(Dec 04 2020 at 18:01)</a>:</h4>
<p>Hmm, not sure how to repro it, but the <code>validate_module_item</code> part was repeating a lot</p>



<a name="218875350"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/Long%20hangs%20in%20publish_diagnostics/near/218875350" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Laurențiu <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/Long.20hangs.20in.20publish_diagnostics.html#218875350">(Dec 04 2020 at 18:46)</a>:</h4>
<p>Might be <a href="https://github.com/rust-analyzer/rust-analyzer/issues/6433">https://github.com/rust-analyzer/rust-analyzer/issues/6433</a></p>



<a name="218875441"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/Long%20hangs%20in%20publish_diagnostics/near/218875441" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jonas Schievink  [he/him] <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/Long.20hangs.20in.20publish_diagnostics.html#218875441">(Dec 04 2020 at 18:47)</a>:</h4>
<p>Yeah</p>



<a name="218875607"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/Long%20hangs%20in%20publish_diagnostics/near/218875607" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jonas Schievink  [he/him] <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/Long.20hangs.20in.20publish_diagnostics.html#218875607">(Dec 04 2020 at 18:49)</a>:</h4>
<p>It looks like navigating to <code>crates/proc_macro_srv/src/proc_macro/bridge/mod.rs</code> reproduces the issue, but I was also seeing some salsa panics when viewing that file, which makes it a bit hard to work with</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>